import request from '@/utils/request';

//获取新闻列表
export function queryPolicyList(params) {
	return request({
		method: 'get',
		url: '/sysPolicy/query',
		params
	});
}

//新增新闻
export function addedPolicy(data) {
	return request({
		method: 'post',
		url: '/sysPolicy/add',
		data
	});
}

//编辑新闻
export function updatePolicy(data) {
	return request({
		method: 'post',
		url: '/sysPolicy/update',
		data
	});
}

//删除新闻
export function deletePolicy(id) {
	return request({
		method: 'get',
		url: '/sysPolicy/delete/' + id
	});
}

//获取新闻详情
export function queryPolicy(id) {
	return request({
		method: 'get',
		url: '/sysPolicy/query/' + id
	});
}